/**
 * A container class that includes all the data needed to update the internal
 * map. Instances of this class are made by the Navigator and sent to the
 * Chartographer for processing while the robot is driving.
 * 
 * @author Emanuel Yifter Lindgren (dv11elr), Anders Lumio (dv11alo)
 *
 */
public class MapUpdate {

    private final double[] echoes;
    private final double[] robotPos;
    private final double robotAngle;

    public MapUpdate(final double[] echoes, final double[] robotPos,
            final double robotAngle) {
        this.echoes = echoes;
        this.robotPos = robotPos;
        this.robotAngle = robotAngle;
    }

    /**
     * Gets the laser echoes when this data was collected.
     * 
     * @return laser echoes
     */
    public double[] getEchoes() {
        return echoes;
    }

    /**
     * Gets the robots position when this data was collected.[X,Y,Z]
     * 
     * @return the position [X,Y,Z]
     */
    public double[] getRobotPos() {
        return robotPos;
    }

    /**
     * Gets the robot heading angle when this data was collected.
     * 
     * @return the heading angle in radians.
     */
    public double getRobotAngle() {
        return robotAngle;
    }
}
